package OrderService

import (
	"context"
	"gdshop-font-api-go/app/request/OrderReq"
	"gdshop-font-api-go/app/service/OrderBaseService"
	"gdshop-font-api-go/library/response"
	"github.com/gogf/gf/frame/g"
)

// RefundList 退款订单列表
func RefundList(ctx context.Context, parames *OrderReq.List) *response.JsonResponse {
	data, err := OrderBaseService.GetPager(ctx, g.Map{
		"delete_at<1 AND member_id=?": parames.MemberId,
	}, parames.Page, parames.PageSize, 0, "")
	if err != nil {
		return response.FailByRequestMessage(nil, err.Error())
	}

	return response.SuccessByRequestMessageData(nil, "成功", data)
}
